package com.example.zhunongzonghe.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;

import java.io.Serializable;
import java.math.BigDecimal;


@Data
@EqualsAndHashCode(callSuper = false)
@Accessors(chain = true)
@TableName("zn_order_details")
public class ZnOrderDetails implements Serializable {

    private static final long serialVersionUID=1L;

    /**
     * 订单详情表
     */
    @TableId(value = "details_id", type = IdType.AUTO)
    private Integer detailsId;

    /**
     * 订单id
     */
    @TableField("order_id")
    private Integer orderId;

    /**
     * 商品id
     */
    @TableField("farm_id")
    private Integer farmId;
    /**
     * 规格id
     */
    @TableField("spec_id")
    private Integer specId;
    /**
     * 地址id
     */
    @TableField("address_id")
    private Integer addressId;

    /**
     * 总价格
     */
    @TableField("total_price")
    private BigDecimal totalPrice;

    /**
     * 商品单价
     */
    @TableField("unit_price")
    private BigDecimal unitPrice;

    /**
     * 商品数量
     */
    @TableField("count")
    private Integer count;
    /**
     * 评价状态,为1时可修改而不可新增
     */
    @TableField("eva_status")
    private Integer evaStatus;
    /**
     * 对应的评价id
     */
    @TableField("evaluate_id")
    private Integer evaluateId;

}
